<div id="ContainAdmin">
	<div id="LeftAdmin">
	<font class="TitleCompte">Liste statistiques par newsletter:</font><br>
	<table width="374" border="0" cellspacing="0" cellpadding="0">
	<?php
	$i=0;
	$req=mysql_query("SELECT * FROM infos_news ORDER BY AnneeNews DESC, MoisNews DESC, JourNews DESC") or die (mysql_error());
	while($row=mysql_fetch_array($req)){
	$idNews=$row['idNews'];
	$NomNews=$row['NomNews'];
	$JourNews=$row['JourNews'];
	$MoisNews=$row['MoisNews'];
	$AnneeNews=$row['AnneeNews'];
	$NomTable="stat_".$idNews;
	$Stop=$row['Stop'];
	
	$i++;
	if($i&1){
	$color="background-color:#F0F0F0;";
	}
	else{
	$color="";
	}
	?>
	 <tr>

    <td width="303" align="left" valign="middle" style="padding:5px 0 2px 0; <?php echo $color; ?> ">
	
	<img src="./images/Arrow.png" alt=">"><?php echo "<strong>".$NomNews."</strong> du ".$JourNews."/".$MoisNews."/".$AnneeNews; ?></td>
	<form action="" method="post">
	<input name="idNews" type="hidden"  value="<?php echo $idNews ?>">
	<td width="35" style="padding:5px 0 2px 0; <?php echo $color; ?> ">
	<input name="Envoyer" type="image" img src="./images/Stat.png" value="Modifier" class="modif"></td></form>
	<td width="36" style="padding:5px 0 2px 0; <?php echo $color; ?> ">
	<?php
	if($Stop==0){ ?>
	<a href="index.php?page=statWeb&idNews=<?php echo $idNews; ?>&Fix=0"><img src="./images/Ouvert.jpg"></a>
	<?php }
	else{ ?>
	<img src="./images/Ferme.jpg">
	<?php } ?>
	</td>
	<?php
	if($Stop==1){ ?>
	<td width="36" style="padding:5px 0 2px 0; <?php echo $color; ?> ">
	<a href=""><img src="./images/Excel.jpg"></a>
	</td>
	<td width="36" style="padding:5px 0 2px 0; <?php echo $color; ?> ">
	<a href="CreaPDF.php?idNews=<?php echo $idNews; ?>" target="_blank"><img src="./images/pdf.jpg"></a>
	</td>
<?php }?>
  </tr>
	<?php
	}
	?>
	</table>
	</div>
	<div id="RightAdmin" >
	<?php
	if(isset($_POST['idNews'])){
	include('app/RecupTableStat.php');
	}
	else{ 
		if(isset($_GET['Fix'])){
		include('app/FixStat.php');
		}
		else{
		
		?>
		<div style="text-align:center; padding:5px 0 20px 0; font-size:18px; ">STATISTIQUES NEWSLETTER<br></div>
		<div class="Separator"><img src="./images/Separator.jpg"></div>
		<div class='StatError'>Choisissez une analyse statistique dans la liste ci-contre.</div>
	<?php 
		}
	}
	?>
	</div>
	<div class="clr"></div>
</div>